# $Id: PKGBUILD 76468 2012-09-18 18:59:40Z jlichtblau $
# Maintainer: Jaroslav Lichtblau <dragonlord@aur.archlinux.org>
# Contributor: Ionut Biru <ibiru@archlinux.org>
# Contributor: Joeny Ang <ang(dot)joeny(at)gmail(dot)com>
# Contributor: Brad Fanella <bradfanella@archlinux.us>

pkgname=libraw
pkgver=0.14.7
pkgrel=1
pkgdesc="A library for reading RAW files obtained from digital photo cameras (CRW/CR2, NEF, RAF, DNG, and others)"
arch=('i686' 'x86_64')
url="http://www.libraw.org/"
license=('CDDL' 'LGPL' 'custom')
depends=('lcms')
options=('!makeflags')
changelog=$pkgname.changelog
source=(http://www.libraw.org/data/LibRaw-${pkgver}.tar.gz)
sha256sums=('7307a607249043bb544f3ab3b3a999e1923d72fbed12e4e2239d172e522143da')

build() {
  cd ${srcdir}/LibRaw-${pkgver}

  ./configure --prefix=/usr
  make
}

package() {
  cd ${srcdir}/LibRaw-${pkgver}

  make DESTDIR=${pkgdir} install
  
#license
  install -D -m644 ${srcdir}/LibRaw-${pkgver}/LICENSE.LibRaw.pdf \
    ${pkgdir}/usr/share/licenses/libraw/LICENSE.LibRaw.pdf
}
